package com.ptswitch.material.service;

import java.util.List;

import com.ptswitch.material.model.common.Uzer;
import com.ptswitch.material.model.contract.Contract;

public interface ContractService {
    static final int Init_Items = 1 << 0;
    static final int Init_Payments = 1 << 1;
    static final int Init_Invoices = 1 << 2;
    static final int Init_Uploads = 1 << 3;

    Contract findById(long id, int init);

    List<Contract> findAllByContractStatus(String status, long first, long size);

    List<Contract> findByVisitor(Uzer visitor, long first, long size);

    String emptyCode(String code);

    void save(Contract contract);

    Contract findById(long id);

    void delete(Contract contract);

    List<Contract> findAll(long first, long size);

    long countAll();

    List<Contract> findLike(String like, long first, long size);

    long countLike(String like);
}
